package com.sky.mapper;

import com.sky.entity.DishFlavor;
import org.apache.ibatis.annotations.Mapper;

import java.util.List;

/**
 * @Description DishFlavorMapper
 * @Author liuqiang
 * @Date 2024/2/19
 */
@Mapper
public interface DishFlavorMapper {

    /**
     * 批量插入口味数据
     * @param flavors
     */
    void insertDishFlavors(List<DishFlavor> flavors);

    /**
     * 根据dish_id删除口味信息
     * @param dishId
     */
    void deleteDishFlavorByDishId(Long dishId);

    /**
     * 根据dishId查询菜品及其对应的口味信息
     * @param dishId
     * @return
     */
    List<DishFlavor> listDishFlavorByDishId(Long dishId);
}
